#ifndef __DECODE_H
#define __DECODE_H



//#define PCM_DEVICE "plughw:0,0"
#define PCM_DEVICE "default"
#define BUFSIZE 8192
#define SAMPLERATE 44100
#define CHANNELS 2

struct buffer {
	int fd;
	unsigned int buflen;
	unsigned int bufpos;
	unsigned char buff[BUFSIZE];
	unsigned int bufsize;
};


/*初始化PCM设备*/
extern int open_pcm_device(void);

/*释放变量*/
extern int close_pcm_device(void);

extern int decode(struct buffer *);

#endif
